package com.dm.biz.item.controller;

import com.dm.biz.item.pojo.DmItem;
import com.dm.biz.item.service.DmItemService;
import com.dm.biz.item.vo.BannerVo;
import com.dm.comm.vo.Result;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
public class DmItemController {

    @Resource
    private DmItemService dmItemService;

    @RequestMapping("index/queryBanner")
    public Result queryBanner(){
        List<BannerVo> list=dmItemService.searchBanner();
       return Result.success("查询首页轮播图成功",list);
    }

}
